<!DOCTYPE html>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<meta name="language" content="ru" />

		<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/styles.css"/>
		<!--[if lte IE 9]>
		<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/styles-9.css" media="screen, projection" />
		<![endif]-->
		<script src="<?php echo Yii::app()->request->baseUrl; ?>/js/jquery.min.js"></script>
		<script src="<?php echo Yii::app()->request->baseUrl; ?>/js/jquery.tmpl.min.js"></script>
		<script src="<?php echo Yii::app()->request->baseUrl; ?>/js/jquery.columnizer.js"></script>
		<script src="<?php echo Yii::app()->request->baseUrl; ?>/js/js.js"></script>
		<script src="<?php echo Yii::app()->request->baseUrl; ?>/js/script.js"></script>
		
		<title><?php echo CHtml::encode($this->pageTitle); ?></title>
	</head>
	<body>
		<div class="main">
            <div class="header">
                <div class="logo">
                    <a href="/" class="site_logo"></a>
                </div>
                <div class="menu_box">
                    <?php 
						$this->widget('application.components.widgets.WMenu',array(
							'type'=>'main',
							'view'=>'mainMenu'
						)); 
					?>
                    <div class="find">
                        <form>
                            поиск <input class="find_input" text="" type="text"><input type="button" class="find_button">
                        </form>
                    </div>                    
                </div>
                <div class="header_right">
                    <div class="login">
						<?php if(Yii::app()->user->isGuest):?>
							<a href="<?php echo $this->createUrl('/user/admin/login');?>">войти</a> / <a href="<?php echo $this->createUrl('/user/admin/register');?>">зарегистрироваться</a>
						<?php else:?>
							<a href="<?php echo $this->createUrl('/user/default/profile');?>"><?php echo Yii::app()->user->getName();?></a> / <a href="<?php echo $this->createUrl('/user/admin/logout');?>">выйти</a>
						<?php endif;?>
					</div>
                    <div class="phone"><div><span>(8452)</span>55-96-89</div></div>
                </div>
            </div>
            <div class="content">
                <div class="left">
                    <?php Context::getInstance()->getWidget('application.components.widgets.ArticlesCategories');?>
					<?php $this->widget('application.components.widgets.ArticlesNew');?>
                    <?php $this->widget('application.components.widgets.ArticlesPopular');?>
                </div>
                <div class="center">
                    <?php echo $content; ?>
                </div>
            </div>
            <div class="footer_box">
                <div class="footer">
                    <?php 
						$this->widget('application.components.widgets.WMenu',array(
							'type'=>'main',
							'view'=>'mainMenuFooter'
						)); 
					?>
                </div>
            </div>
        </div>
    </body>
</html>